package com.oulu.ruokkis.parser;

import java.util.List;

import com.oulu.ruokkis.model.Restaurant;

/**
 * 
 * @author antti.vainik@gmail.com
 *
 * RSSMenu parser is implemented with Strategy pattern.
 * The idea is to make parser implementation interchangeable on-the-fly.
 * If there are several RSS feeds available, and they have different structure,
 * we can have different implementation for each.
 * 
 * 
 */


public class RSSMenuContext {
	
	private RSSMenuParser parser = null;
	
	
	// TODO implement logic for switching between RSS feeds
	
	public RSSMenuContext()
	{
		
	}

	public RSSMenuParser getParser() {
		return parser;
	}

	public void setParser(RSSMenuParser parser) {
		this.parser = parser;
	}
	
	public List<Restaurant> parseAll(){
		return parser.parseAll();
	}

}
